import type { RouteRecordRaw } from 'vue-router';

import { BasicLayout } from '#/layouts';
import { $t } from '#/locales';

const routes: RouteRecordRaw[] = [
  {
    component: BasicLayout,
    meta: {
      icon: 'tabler:tools',
      order: 2,
      title: $t('page.tools.title'),
    },
    name: 'tools',
    path: '/todos',
    children: [
      {
        name: 'Todos',
        path: '/todos',
        component: () => import('#/views/tools/todos/index.vue'),
        meta: {
          affixTab: false,
          icon: 'lucide:list-todo',
          title: $t('page.tools.todos'),
        },
      },
      {
        name: 'Html2md',
        path: '/html2md',
        component: () => import('#/views/tools/html2md/index.vue'),
        meta: {
          affixTab: false,
          icon: 'lucide:file-code',
          title: $t('page.tools.html2md'),
        },
      },
      {
        name: 'QRCode',
        path: '/qrcode',
        component: () => import('#/views/tools/qrcode/index.vue'),
        meta: {
          affixTab: false,
          icon: 'heroicons:qr-code-16-solid',
          title: $t('page.tools.qrcode'),
        },
      },
      {
        name: 'Regex',
        path: '/regex',
        component: () => import('#/views/tools/regex/index.vue'),
        meta: {
          affixTab: false,
          icon: 'bi:regex',
          title: $t('page.tools.regex'),
        },
      },
    ],
  },
];

export default routes;
